@import url("https://fonts.googleapis.com/css?family=Poppins:300,400,900&display=swap");

html {
  width: 100%;
  height: 100vh;

  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: var(--lightBg);

  --lightBtn: #fe016c;
  --lightBg: #fff;
  --lightColor: #232323;
}

html[data-theme="dark"] {
  background: var(--lightBg);
  --lightBtn: #ffbd07;
  --lightBg: #232323;
  --lightColor: #fff;
}

h1 {
  font-family: "Poppins", sans-serif;
  font-weight: 300;
  color: var(--lightColor);
}

input[type="checkbox"] {
  height: 0;
  width: 0;
  visibility: hidden;
}

label {
  cursor: pointer;
  text-indent: -9999px;
  width: 55px;
  height: 30px;
  background: var(--lightBtn);
  margin: 0 auto;
  display: flex;
  justify-content: center;
  align-items: center;
  -webkit-border-radius: 100px;
  -moz-border-radius: 100px;
  border-radius: 100px;
  position: relative;
}

label:after {
  content: "";
  background: #fff;
  width: 20px;
  height: 20px;
  -webkit-border-radius: 50%;
  -moz-border-radius: 50%;
  border-radius: 50%;
  position: absolute;
  top: 5px;
  left: 4px;
  transition: cubic-bezier(0.68, -0.55, 0.27, 01.55) 320ms;
}

input:checked + label {
  background: #ffbd07;
}

input:checked + label:after {
  left: calc(100% - 5px);
  -webkit-transform: translateX(-100%);
  -moz-transform: translateX(-100%);
  -ms-transform: translateX(-100%);
  -o-transform: translateX(-100%);
  transform: translateX(-100%);
}
